<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>表格</title>
<meta name="description" content="">
<meta name="keywords" content="">
<link href="" rel="stylesheet">
<style>
    table{
        width: 1200px;
        border-collapse: collapse;
        margin: 30px auto;
    }
    td{
        border: 1px solid #ccc;
    }
</style>
</head>
<body>
    <script>
    document.write("<h1 align=center>李宁（中国）体育用品有限公司应聘简历表</h1>")
    var str = "";
    var arr = ["应征岗位","为确保我们在面试过程中更全面的了解您的信息，请您尽量按规定内容填写完毕，谢谢！",["姓名","张三","性别","男","身高","180cm","<img src=\"1.jpg\" alt=\"这是照片\" title=\"李四\">"],["政治面貌","团员","民族","汉","婚否","未婚"],["现居地址","河南省郑州市XXXXXXXXXXX"],[1,2,3,4,5,6,'',],['',2,3,4,5,6,'',]]
    var table = "<table>";
    for(var i = 0;i < arr.length;i++){
        table +="<tr>";
        // var arrType = typeof arr[i];
        if(typeof arr[i] == "string"){
                table +="<td colspan=\"7\" >"+arr[i]+"</td>"  
        }else {
           for(var j = 0;j < arr[i].length;j++){
                if(i == 2 && j == arr[2].length-1){
                    table +="<td rowspan=\"3\" width=150px>"+arr[i][j]+"</td>"
                }else if(i == 4 && j == 0){
                    table +="<td colspan=\"2\" bgcolor=#e7e7e7 align=center>"+arr[i][j]+"</td>"
                }else if(i == 4 && j == 1){
                    table +="<td colspan=\"4\" align=center>"+arr[i][j]+"</td>"
                }else if(j == 0||j == 2||j == 4){
                    table +="<td width=150px bgcolor=#e7e7e7 align=center>"+arr[i][j]+"</td>"
                }else{
                     table +="<td align=center>"+arr[i][j]+"</td>"
                }
            } 
        }
        table +="</tr>"
        str = table;
    }
    table +="</table>";
    document.write(str);
    </script>
</body>
</html>